// @ts-ignore
/* eslint-disable */
import { request } from '@umijs/max';

/** addPost POST /api/interfanceinfo/add */
export async function addPostUsingPOST(
  body: API.InterfanceInfoAddRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponselong>('/api/interfanceinfo/add', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** deletePost POST /api/interfanceinfo/delete */
export async function deletePostUsingPOST(
  body: API.DeleteRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseboolean>('/api/interfanceinfo/delete', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** getPostById GET /api/interfanceinfo/get */
export async function getPostByIdUsingGET(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getPostByIdUsingGETParams,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseInterfanceInfo>('/api/interfanceinfo/get', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  });
}

/** invodeInterfance POST /api/interfanceinfo/invoke */
export async function invodeInterfanceUsingPOST(
  body: API.InterfanceInvokeRquest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseobject>('/api/interfanceinfo/invoke', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** listPost POST /api/interfanceinfo/list */
export async function listPostUsingPOST(
  body: API.InterfanceInfoQueryRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseListInterfanceInfo>('/api/interfanceinfo/list', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** listPostByPage POST /api/interfanceinfo/list/page */
export async function listPostByPageUsingPOST(
  body: API.InterfanceInfoQueryRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseIPageInterfanceInfo>('/api/interfanceinfo/list/page', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** offInterfance POST /api/interfanceinfo/offline */
export async function offInterfanceUsingPOST(
  body: API.UpdateRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseboolean>('/api/interfanceinfo/offline', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** puhlishInterfance POST /api/interfanceinfo/online */
export async function puhlishInterfanceUsingPOST(
  body: API.UpdateRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseboolean>('/api/interfanceinfo/online', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** updatePost POST /api/interfanceinfo/update */
export async function updatePostUsingPOST(
  body: API.InterfanceInfoUpdateRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseboolean>('/api/interfanceinfo/update', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}
